#include "loadingwidget.h"
#include <QWidget>
//#include <QProgressBar>
#include <QBoxLayout>
#include <QLabel>
#include <QCloseEvent>

LoadingWidget::LoadingWidget( Qt::WidgetAttribute screenOrientation, QWidget * parent ):
	QWidget( parent )
{
	setAttribute( Qt::WA_DeleteOnClose );
//	setWindowModality( Qt::WindowModal );
//#if defined( Q_WS_MAEMO_5 ) || defined( Q_WS_HILDON )
//	setAttribute( screenOrientation, true );
//#endif
	QLabel * lbl = new QLabel( tr( "Loading. Please wait..." ), this );
	lbl->setAlignment( Qt::AlignHCenter | Qt::AlignVCenter );
//	QProgressBar * progress = new QProgressBar( this );
//	progress->setMinimum( 0 );
//	progress->setMaximum( 0 );
	QBoxLayout * layout = new QBoxLayout ( QBoxLayout::TopToBottom, this );
	layout->addWidget( lbl );
//	layout->addWidget( progress );
	setLayout( layout );
}
